const { Ranking } = require('@/models/report');
const getRankings = async (req, res) => {
    const { type, category } = req.params;
    const rankings = await Ranking.getRankings(type, category);
    res.json(rankings);
}
const generateRankings = async (req, res) => {
    const { type, category } = req.params;
    const rankings = await Ranking.generateRankings(type, category);
    res.json(rankings);
}
const distributeRewards = async (req, res) => {
    const { type, category } = req.params;
    const rankings = await Ranking.distributeRewards(type, category);
    res.json(rankings);
}
const getHistory = async (req, res) => {
    const { type, category } = req.params;
    const rankings = await Ranking.getHistory(type, category);
    res.json(rankings);
}
module.exports = {
    getRankings,
    generateRankings,
    distributeRewards,
    getHistory
}